
/// 属于哪一端
export enum Belonging{
  universal = 1,
  b_side = 2,
  c_side = 3
}

/// banner 状态
export enum BannerState {
  common = 1,
  limitReached = 11,
  activityJoined = 12,
  finished = 98,
  offShelf = 99
}

// banner
export interface BannerInfo {
  bannerId: string,
  imgPath :string,
  jumpPage: string,
  publishTime: Date,
  belonging: Belonging, // 
  status : number,
  briefDescribe :string,
}

// 新闻咨讯
export interface newsInfo {
  infoId : string,
  infoTitle : string,
  infoDate :Date,
  infoThumb : string,
  status : BannerState,
  Belonging : Belonging,
  briefDescribe : string,
}

/// 课程类型
export enum CourseMode{
  Video = 1, // 录播课程
  Stream = 2 // 直播课程
}

/// 课程状态
export enum CourseState {
  Common = 1, // 
  OffShelf = 99, // 课程已下架
}

/// 课程归属
export enum CourseBelonging {
  All = 1, // 机构学生都可以购买
  OrganOnly = 2, // 机构专属
  StudentOnly = 3, // 学生专属
}

//课程信息
export interface courseInfo {
  courseId :string,
  courseName : string,
  courseThumb : string,
  briefDescribe : string,
  courseType: number,
  courseSecondType : number,
  price: number,
  discountPrice : number,
  months:number,
  courseMode : CourseMode,
  validYears: number,
  containsPreCourse:boolean,
  vipOnly :boolean,
  containsExam:boolean,
  status : CourseState,
  purchaseCount: number,
  isOrganRecommend :boolean,
  isStudentRecommend :boolean,
  isRecommend :boolean,
  courseBelonging : CourseBelonging
}


// base 
export interface BaseInfo<T> {
  isSuccess:boolean,
  code:string,
  message:string,
  result: T[],
}


// export interface UserState {
//   user_id?: string
//   user_name?: string
//   real_name?: string
//   avatar?: string
//   desc?: string
//   password?: string
//   token?: string
//   organization?: string
//   location?: string
//   email?: string
//   auths?: string[]
//   is_admin?: number
//   blogJuejin?: string
//   blogZhihu?: string
//   blogGithub?: string
//   profileBio?: string
//   devLanguages?: string
//   role?: RoleType
// }

export enum StudentState { // 学生状态枚举
  RegSucceed = 1,
  Reging = 91,
  Banned = 99,
}

export interface TeacherInfo { // 教师信息
  teacherId: string,
  teacherName: string,
  teacherThumb : string,
  teacherBriefDescribe: string,
  phone: string,
  teacherState: StudentState
}